import VueRouter from "vue-router";
import store from "@/store";
const router = new VueRouter({
    mode:'hash'
})
// 全局路由守卫

//前置路由守卫
router.beforeEach((to,from,next)=>{
   
   if(to.meta.title) document.title=to.meta.title
    store.commit('temporary/setpagemark',!to.meta ? null  : to.meta.pagemark)
    
   next()
})

export default router